<?php
// +----------------------------------------------------------------------
// | xiongrui [ WE CAN DO IT JUST THINK IT ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013 http://www.xiongrui.cn All rights reserved.
// +----------------------------------------------------------------------
// | Author: molong <molong@tensent.cn> <http://www.xiongrui.cn>
// +----------------------------------------------------------------------
namespace app\common\model;


class AddressNew extends Base{

  protected $insert = ['status' => 1,'user_id'=>USER_ID];
  protected $type       = [
         'create_time' => 'timestamp:Y/m/d h:i:s',
  ];

  public function changes($data){
		if (isset($data['id']) && $data['id']) {
			return $this->save($data, array('id'=>$data['id']));
		}else{
			return $this->save($data);
		}
	}

}
